<html>
<head>
<title> Including Directives into Web Server Configuration File </title>
<meta name="Keywords" content="" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" href="stylesheet.css"/>
<script src="locate.js"></script>
<link href="prettify.css" type="text/css" rel="stylesheet" />
<script type="text/javascript" src="prettify.js"></script>
</head>
<script src="highlight.js"></script>
<body bgcolor="#FFFFFF" text="#000000" link="#0000A0" alink="#008000" vlink="#FF0000" onLoad="FindCorrectTOCPage(); prettyPrint()">
<table cellpadding="0" cellspacing="0" border="0">
<tr valign="top">
<td>
<p class="pagenavigation"><a href="28448.htm" target="_self"><img src="38976.gif" alt="Previous page" height="16" width="16" vspace="0" hspace="1" align="top" border="0"> Previous page</a></p></td>
<td>
<p class="pagenavigation"><a href="24946.htm" target="_self"><img src="38977.gif" alt="Next page" height="16" width="16" vspace="0" hspace="1" align="top" border="0"> Next page</a></p></td>
<td>
<p class="pagenavigation"><a href="toc41518231.htm" target="TOC"><img src="38970.gif" alt="Locate page" height="16" width="16" vspace="0" hspace="1" align="top" border="0"> Locate page</a></p></td>
<td>
<p class="pagenavigation"><a href="toc41518231.htm" target="TOC"><a class="" title="" href="javascript:print();" target="_self"><img src="39072.gif" alt="Print this page" height="16" width="16" vspace="0" hspace="1" align="top" border="0"></a></a></p></td>
</tr>
</table>
<h2 class="heading2">Including Directives into Web Server Configuration File</h2>
<p class="bodytext">You can include domain-specific Apache configuration directives into web server configuration file. In Plesk each domain has virtual hosts configuration stored in a separate file <code class="monospace">httpd.include</code>.</p>
<p class="bodytext">On all Linux systems, this file is located in the directory <code class="monospace">/var/www/vhosts/&lt;domain-name&gt;/conf/</code>.</p>
<p class="bodytext">On FreeBSD systems, this file is located in the directory <code class="monospace">/usr/local/psa/home/vhosts/&lt;domain-name&gt;/conf/</code>.</p>
<p class="bodytext">If you upgraded from Plesk version 7.5.4 or earlier, try looking for this file in the directory <code class="monospace">/home/httpd/vhosts/&lt;domain-name&gt;/conf/</code>.</p>
<p class="note"><strong class="buttons">Note:</strong> you can change the location of virtual host directories using the <code class="monospace">transvhosts.pl</code> utility, which is located either in <code class="monospace">/usr/local/psa/bin/</code> or <code class="monospace">/opt/psa/bin/</code> directory, depending on your operating system.</p>
<p class="bodytext">This file is overwritten each time the virtual host configuration is changed, thus any manual alterations made to the file are discarded. To use custom directives or redefine those inserted by Plesk, you need to create the files <code class="monospace">vhost.conf </code>and/or <code class="monospace">vhost_ssl.conf</code> with necessary directives in the directory <code class="monospace">/path_to_vhosts/&lt;domain-name&gt;/conf/</code> for a domain, and <code class="monospace">/path_to_vhosts/&lt;domain-name&gt;/subdomains/&lt;subdomain-name&gt;/conf/</code> for a subdomain.</p>
<p class="bodytext">If any of these files exist by the time the main configuration file is generated, Plesk inserts the appropriate Include directive into the HTTP and/or HTTPS virtual host context respectively. For security reasons, only root can create the <code class="monospace">vhost.conf</code> and <code class="monospace">vhost_ssl.conf</code> files.</p>
<p class="bodytext">For the changes to take effect, you need to run the following command:</p>
<p class="preformattedbold"></p>
<p class="preformattedbold">/plesk_installation_directory/admin/sbin/websrvmng --reconfigure-vhost --vhost-name=&lt;domain_name&gt; </p>
<p class="preformattedbold"></p>


</body>
<script>highlightTOC()</script>
</html>

